
import request from '../utils/request'
import API from './constants'

// 异步登录 这个API在redux actions里面调用
export const login = ({ username, password }) => request({
  url: API.SESSION_API,
  method: 'POST',
  data: {
    username,
    password
  }
})